View.ShapeDecoration

Decoration object that describes visualization properties for shapes and points.

View.ShapeDecoration.create()
Return type:

View.ShapeDecoration

Creates a new ShapeDecoration.

The default values for the decoration are:

  • lineWidth = 1.0

  • lineColor = (0, 0, 0, 255)

  • fillColor = (0, 0, 0, 0)

  • pointType = “DOT”

  • pointSize = 3.0

These values can be changed by using the corresponding functions.

View.ShapeDecoration.setFillColor(deco, red, green, blue, alpha)
Arguments:
Return type:

View.ShapeDecoration

Sets the fill color. It will be used to fill shape iconics.

View.ShapeDecoration.setLineColor(deco, red, green, blue, alpha)
Arguments:
Return type:

View.ShapeDecoration

Sets the line color. It will be used for line, points and text iconics as well as stroke color for shape iconics.

View.ShapeDecoration.setLineWidth(deco, width)
Arguments:
Return type:

View.ShapeDecoration

Set the line width.

View.ShapeDecoration.setPointSize(deco, size)
Arguments:
Return type:

View.ShapeDecoration

Sets the point size for point iconics.

View.ShapeDecoration.setPointType(deco, type)
Arguments:
Return type:

View.ShapeDecoration

Sets the display type for point iconics.

View.ShapeDecoration.toString(shapeDecoration)
Argument:
Return type:

string

Gets a user-friendly string description of the shape decoration.